package com.huawei.hms.framework.network.restclient.hwhttp;

import java.io.IOException;
import java.io.OutputStream;
import javax.annotation.Nullable;

class RequestBody$3 extends RequestBody {
    final /* synthetic */ int val$byteCount;
    final /* synthetic */ byte[] val$content;
    final /* synthetic */ MediaType val$contentType;
    final /* synthetic */ int val$offset;

    RequestBody$3(MediaType mediaType, int i, byte[] bArr, int i2) {
        this.val$contentType = mediaType;
        this.val$byteCount = i;
        this.val$content = bArr;
        this.val$offset = i2;
    }

    public byte[] body() {
        return new byte[0];
    }

    @Nullable
    public String contentType() {
        return this.val$contentType == null ? null : this.val$contentType.toString();
    }

    public long contentLength() {
        return (long) this.val$byteCount;
    }

    public void writeTo(OutputStream outputStream) throws IOException {
        outputStream.write(this.val$content, this.val$offset, this.val$byteCount);
    }
}
